/**
 * @file worker-loader-proxy
 * @author liaoxuezhi@baidu.com
 *
 * 由于 js 部署在 cdn 上，不允许跨域，所以需要此文件中转一下。
 */
/* eslint-disable */
/* eslint fecs-camelcase: [2, {ignore: ["/^include_path/"]}] */

function noJsExt(raw) {
  return raw.replace(/\.js$/, '');
}

self.MonacoEnvironment = {
  baseUrl: __uri('/client/node_modules/monaco-editor/min/vs/loader.js').replace(/vs\/.*$/, ''),
  paths: {
    'vs': noJsExt(__uri('/client/node_modules/monaco-editor/min/vs/editor/editor.main.js')),
    'vs/base/worker/workerMain': noJsExt(__uri('/client/node_modules/monaco-editor/min/vs/base/worker/workerMain.js')),


    'vs/basic-languages/src/css': noJsExt(__uri('/client/node_modules/monaco-editor/min/vs/basic-languages/src/css')),

    'vs/editor/editor.main': noJsExt(__uri('/client/node_modules/monaco-editor/min/vs/editor/editor.main.js')),
    'vs/basic-languages/src/markdown': noJsExt(__uri('/client/node_modules/monaco-editor/min/vs/basic-languages/src/markdown.js ')),
    'vs/editor/editor.main.css': noJsExt(__uri('/client/node_modules/monaco-editor/min/vs/editor/editor.main.css')),
    'vs/editor/editor.main.nls': noJsExt(__uri('/client/node_modules/monaco-editor/min/vs/editor/editor.main.nls.js')),
    'vs/editor/editor.main.nls.zh-cn': noJsExt(__uri('/client/node_modules/monaco-editor/min/vs/editor/editor.main.nls.zh-cn.js')),

    'vs/editor/contrib/suggest/browser/symbol-sprite.svg': noJsExt(__uri('/client/node_modules/monaco-editor/min/vs/editor/contrib/suggest/browser/symbol-sprite.svg')),
    'vs/editor/contrib/quickOpen/browser/symbol-sprite.svg': noJsExt(__uri('/client/node_modules/monaco-editor/min/vs/editor/contrib/quickOpen/browser/symbol-sprite.svg')),

    'vs/language/typescript/src/mode': noJsExt(__uri('/client/node_modules/monaco-editor/min/vs/language/typescript/src/mode.js')),
    'vs/language/typescript/lib/typescriptServices': noJsExt(__uri('/client/node_modules/monaco-editor/min/vs/language/typescript/lib/typescriptServices.js')),
    'vs/language/typescript/src/worker': noJsExt(__uri('/client/node_modules/monaco-editor/min/vs/language/typescript/src/worker.js')),

    'vs/language/json/jsonMode': noJsExt(__uri('/client/node_modules/monaco-editor/min/vs/language/json/jsonMode.js')),
    'vs/language/json/jsonWorker': noJsExt(__uri('/client/node_modules/monaco-editor/min/vs/language/json/jsonWorker.js')),

    'vs/language/css/cssMode': noJsExt(__uri('/client/node_modules/monaco-editor/min/vs/language/css/cssMode.js')),
    'vs/language/css/cssWorker': noJsExt(__uri('/client/node_modules/monaco-editor/min/vs/language/css/cssWorker.js'))
  }
};
importScripts(__uri('/client/node_modules/monaco-editor/min/vs/base/worker/workerMain.js'));